package com.zxt.content.copywriting.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zxt.content.copywriting.model.PublicCopywriting;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface PublicCopywritingMapper extends BaseMapper<PublicCopywriting> {

    /**
     * 批量保存并返回id
     *
     * @param saveList
     */
    void saveBatchAndReturnId(@Param("list") List<PublicCopywriting> saveList);

    /**
     * 随机获取一条推送的文案
     *
     * @return
     */
    PublicCopywriting randGetOneByUserId();
}
